home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
DDJMAG
/
DDJ9110.ZIP
/
STRING.ZIP
/
STRICASE.CPP
< prev
next >
Wrap
C/C++ Source or Header
|
1991-07-30
|
449b
|
23 lines
#include <string.h>
#include <ctype.h>
#include <errno.h>
#include <string.hpp>
String String::upper() const
{
String t(body(),length());
char *p = t.body();
for (int i = 0; i < length(); ++i, ++p)
*p = toupper(*p);
return t;
}
String String::lower() const
{
String t(body(), length());
char *p = t.body();
for (int i = 0; i < length(); ++i, ++p)
*p = tolower(*p);
return t;
}